Magnetic valves for use in brake systems are known that are equipped with rigidly disposed connection devices and an electrical cable plug located on the housing. When they are used in a non-rotatable structural part, such as a master brake cylinder, the housing and the cable plug cannot be properly aligned.